from enum import Enum

from pydantic import BaseModel

# 定义消息角色和消息模型
class MessageRole(str, Enum):
    USER = "user"
    ASSISTANT = "assistant"
    SYSTEM = "system"

class ChatMessage(BaseModel):
    role: MessageRole
    content: str